package com.zzl.bonds.ticket.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.zzl.apidoc.annotation.ApidocModel;
import com.zzl.apidoc.annotation.ApidocModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 转让申请单
 *
 * @author sunpp
 * @date 2022-02-16 11:14:07
 */
@Data
@TableName("t_ticket_transfer")
@ApidocModel
@SuppressWarnings("javadoc")
public class TicketransferEntity implements Serializable {
    private static final long serialVersionUID = 1L;

    @TableId(type = IdType.UUID)
    @ApidocModelProperty(description = "主键")
    private String id;
    @ApidocModelProperty(description = "转让编号")
    private String transferNo;
    @ApidocModelProperty(description = "转让方方id")
    private String transferEnterpriseId;
    @ApidocModelProperty(description = "转让方企业名称")
    private String transferEnterpriseName;
    @ApidocModelProperty(description = "转让方企业社会统一代码")
    private String transferCreditCode;

    @ApidocModelProperty(description = "转让后子票据id")
    private String ticketId;
    @ApidocModelProperty(description = "票据编号")
    private String ticketNo;
    @ApidocModelProperty(description = "转让后留存的票据id")
    private String ticketRetentionId;
    @ApidocModelProperty(description = "转让后留存的票据编号")
    private String ticketRetentionNo;
    @ApidocModelProperty(description = "转让后留存的票据金额")
    private Double ticketRetentionAmount;

    @ApidocModelProperty(description = "转让金额")
    private Double transferAmount;
    @ApidocModelProperty(description = "剩余金额")
    private Double surplusAmount;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApidocModelProperty(description = "开单日期，及开立里的日期", validate = "yyyy-MM-dd HH:mm:ss")
    private Date invoiceTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApidocModelProperty(description = "到期日期", validate = "yyyy-MM-dd HH:mm:ss")
    private Date expireTime;
    @ApidocModelProperty(description = "1：内部复核中 2、平台审批中 3、收单企业签收中\n" +
            " 4、收单企业驳回 5、内部复核未通过，6、平台审批未通过，7 已撤销，8已签收")
    private Integer ticketStatus;
    @ApidocModelProperty(description = "母单票据id")
    private String parentTicketId;
    @ApidocModelProperty(description = "母单票据编号")
    private String parentTicketNo;
    @ApidocModelProperty(description = "母单票据金额")
    private Double parentAmount;
    @ApidocModelProperty(description = "签收方id")
    private String receiveEnterpriseId;
    @ApidocModelProperty(description = "签收方企业名称")
    private String receiveEnterpriseName;
    @ApidocModelProperty(description = "签收方企业社会统一代码")
    private String receiveCreditCode;

    @ApidocModelProperty(description = "收单备注")
    private String receiveRemark;
    @ApidocModelProperty(description = "基础交易合同编号")
    private String contractNo;
    @ApidocModelProperty(description = "应收账款金额", example = "")
    private Double accountsReceivableAmount;
    @ApidocModelProperty(description = "0 未预兑付 1 进入预兑付。描述：当开立申请单进入预兑付时更改状态。")
    private Integer advancePaymentStatus;
    @ApidocModelProperty(description = "企业id,权限使用")
    private String enterpriseId;
    @ApidocModelProperty(description = "部门id")
    private Integer orgId;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApidocModelProperty(description = "创建时间", validate = "yyyy-MM-dd HH:mm:ss")
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApidocModelProperty(description = "修改时间", validate = "yyyy-MM-dd HH:mm:ss")
    @TableField(fill = FieldFill.INSERT)
    private Date updateTime;
    @ApidocModelProperty(description = "创建人")
    private Integer creatorId;
    @ApidocModelProperty(description = "修改人")
    private Integer updaterId;
    @ApidocModelProperty(description = "备注")
    private String remark;
    @ApidocModelProperty(description = "复核备注", example = "")
    private String  recheckRemark;
    @ApidocModelProperty(description = "复核时间", validate = "yyyy-MM-dd HH:mm:ss")
    private Date reviewTime;
    @ApidocModelProperty(description = "复核人")
    private Integer reviewId;

    @ApidocModelProperty(description = "签收时间", validate = "yyyy-MM-dd HH:mm:ss")
    private Date signTime;
    @ApidocModelProperty(description = "签收人")
    private Integer signId;
    @ApidocModelProperty(description = "签收备注", example = "")
    private String signRemark;
    @ApidocModelProperty(description = "平台审批时间", validate = "yyyy-MM-dd HH:mm:ss")
    private Date platApprovalTime;
    @ApidocModelProperty(description = "平台审批备注")
    private String platApprovalRemarks;
    @ApidocModelProperty(description = "平台审批人id")
    private Integer platApprovalId;

    @ApidocModelProperty(description = "金融机构Id")
    private String instinctyId;
    @ApidocModelProperty(description = "金融机构名称")
    private String instinctyName;

    @ApidocModelProperty(description = "开单方id")
    private String openEnterpriseId;
    @ApidocModelProperty(description = "开单方企业名称")
    private String openEnterpriseName;
    @ApidocModelProperty(description = "开单方企业社会统一代码")
    private String openCreditCode;

    @ApidocModelProperty(description = "来源票据 开票申请表id（可关联上传附件等信息）")
    private String ticketOpenId;
}
